package creational.singleton;

/**
 * @Description: 饿汉式2
 * @Author: lxt
 * @CreateDate: 2019/11/1
 **/
public class Singleton2 {
    private final static Singleton2 instance;

    static {
        instance = new Singleton2();
    }

    private Singleton2() {

    }

    public static Singleton2 getInstance() {
        return instance;
    }
}
